package com.prs.crm.service.cdxh;

import java.util.List;

import com.prs.crm.domain.cdxh.SaleOrder;
import com.prs.crm.domain.cdxh.SaleOrderDetail;
import com.prs.crm.domain.cdxh.cd_Product;
import com.prs.crm.domain.cdxh.printing.PrintingTeam;
import com.prs.crm.domain.stock.Product;
import com.prs.crm.service.BaseService;

public interface SaleOrderService extends BaseService<SaleOrder> {
   void saveRegister(SaleOrder saleCustomer,String[] productCodes,
			String[] pronames, String[] productNorms, String[] productColors,
			String[] productpackges, String[] productNums,
			String[] productUnits, String[] poductPrices,
			String[] productSquares,String[] prototalPrices);
   String getsaleNum();
   
  void setAllRushOrder(SaleOrder saleOrder);
  
  SaleOrder  getSaleOrder(java.io.Serializable id);
  /**
   * 设置状态
   * @param plancode
   * @param proCode
   * @return
   */
  String setSaleState(String plancode,String proCode);
  /**
   * 生产计划数量变更
   */
  void  setProPlanNums(SaleOrder saleOrder,String[] nums,String[] productCodes );
  
  /**
	 *  根据产品编号和对象的ID号查找
	 * @param productCode
	 * @param aleOrder
	 * @return
	 */
	SaleOrderDetail getSaleOrderDetail(String productCode,SaleOrder aleOrder);
	
	void saveOrudetail(SaleOrderDetail saleOrderDetail);
	
	void saveOrudsale(SaleOrder saleOrder);
	
	SaleOrder getSaleOrder(String orders);
  /**
   *销售订单删除操作
   */
	void setSaleOrders(Integer[] ids);
	
	
	/**
	 * 销售主菜单
	 * @param so
	 */
	void removeSaleOrder(SaleOrder so);
	/**
	 * 销售菜单明细
	 * @param sod
	 */
	void removeSaleOrderDetail(SaleOrderDetail sod);
	
	List<SaleOrderDetail>  getSaleOrderDetails(SaleOrder saleOrders);
 
	/**
	 * 根据产品编号查询
	 */
	SaleOrderDetail getSaleOrderDetailByproductCode(String productCode);
  /**
   * 根据产品查找订单
   * @param product
   * @return
   */
	SaleOrderDetail getSaleOrderDetailByProduct(cd_Product product);
}
